package com.gebro.classifier;


public class Main {

	/**
	 * @param args
	 */
	public static void main(String[] args) {


		MatrixElement el1 = new MatrixElement("A", new Point(1.0, 1.1));
		MatrixElement el2 = new MatrixElement("B", new Point(1.0, 1.0));
		MatrixElement el3 = new MatrixElement("C", new Point(0, 0.2));
		MatrixElement el4 = new MatrixElement("D", new Point(0, 0.1));
		Matrix matrix = new Matrix();
		matrix.addElement(el1);
		matrix.addElement(el2);
		matrix.addElement(el3);
		matrix.addElement(el4);

		EuclideanDistance ed = new EuclideanDistance(matrix, new Point(1.0, 1.520254));
		MatrixElement nearest = ed.getNearestPoint();
		System.out.println(nearest.getLabel());

	}

}
